//
//  SmallCollectionViewCell.m
//  22--HomeWork QQ音乐界面
//
//  Created by 冀永金 on 16/8/14.
//  Copyright © 2016年 冀永金. All rights reserved.
//

#import "SmallCollectionViewCell.h"

@interface SmallCollectionViewCell ()

@end

@implementation SmallCollectionViewCell
- (instancetype)initWithFrame:(CGRect)frame {
    self = [super initWithFrame:frame];
    if (self) {
        self.image = [[UIImageView alloc]init];
        [self.contentView addSubview:_image];
        //_image.backgroundColor = [UIColor yellowColor];
        self.nameLabel = [[UILabel alloc]init];
        self.nameLabel.textAlignment = 1;
        [self.contentView addSubview:_nameLabel];
        self.nameLabel.textColor = [UIColor blackColor];
        
        //_nameLabel.backgroundColor = [UIColor blueColor];
    }
    return self;
}
- (void)layoutSubviews {
    [super layoutSubviews];
    self.image.frame = CGRectMake(self.bounds.size.width / 2 - 20, 20, 40, 40);
    //self.image.layer.cornerRadius = 20;
    //self.image.clipsToBounds = YES;
    self.nameLabel.frame = CGRectMake(self.bounds.size.width / 2 - 35, 70, 70, 25);
    
    //self.image.center.y : self.center =
}

@end
